-
Notifications
You must be signed in to change notification settings - Fork 300
feat: keep internal error in worker's quit reason #372
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR enhances error handling in the transport worker system by making the WorkerQuitReason
generic over error types, allowing workers to preserve their specific error types rather than converting them to strings. It also fixes spelling errors in StreamableHttpError
variants.
Key changes:
- Made
WorkerQuitReason
generic over error types to preserve internal error information - Updated all worker implementations to use specific error types instead of generic string errors
- Fixed typos in
StreamableHttpError
enum variants (Sever
→Server
)
Reviewed Changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 2 comments.
File | Description |
---|---|
crates/rmcp/src/transport/worker.rs |
Made WorkerQuitReason generic over error type E and updated method signatures |
crates/rmcp/src/transport/streamable_http_server/session/local.rs |
Introduced LocalSessionWorkerError enum and updated worker implementation to use specific error types |
crates/rmcp/src/transport/streamable_http_client.rs |
Fixed spelling errors and updated to use generic error types in method calls |
crates/rmcp/src/transport/common/reqwest/streamable_http_client.rs |
Fixed spelling error in error variant name |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
Just adopted copilot's suggestion. |
fix #345
Motivation and Context
How Has This Been Tested?
Breaking Changes
QuitReason
StreamableHttpError
Types of changes
Checklist
Additional context